# Maintainer: Ivan Semkin (ivan at semkin dot ru)

pkgname=thumbnailer-git
_pkgname=thumbnailer
pkgver=r1938.ec1c06a
pkgrel=3
pkgdesc='D-Bus service for out of process thumbnailing'
url='https://github.com/ubports/thumbnailer'
arch=(x86_64 i686 armv7h aarch64)
license=(GPL)
conflicts=(thumbnailer)
provides=(thumbnailer)
depends=(boost qt5-base qt5-quickcontrols gstreamer gst-plugins-base gdk-pixbuf2 libexif unity-api-git apparmor taglib persistent-cache-cpp-bzr)
makedepends=(git cmake)
source=('git+https://github.com/ubports/thumbnailer.git')
sha256sums=('SKIP')

prepare() {
  cd ${_pkgname}
  git checkout bionic
}

pkgver() {
  cd ${_pkgname}
  echo "r$(git rev-list --count HEAD).$(git describe --always)"
}

build() {
  cd ${_pkgname}
  cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr -DCMAKE_INSTALL_LIBDIR="lib/" .
  make
}

package() {
  cd ${_pkgname}
  make DESTDIR="${pkgdir}/" install
}
# vim:set ts=2 sw=2 et:
